import { request } from '@/utils'

export function getTagList(tagDTO) {
  return request({
    url: '/admin/getTagList',
    method: 'POST',
    data: JSON.stringify(tagDTO),
    headers: {
      'Content-type': 'application/json;charset=utf-8',
    },
  })
}

export function addTag(tagDTO) {
  return request({
    url: '/admin/addTag',
    method: 'POST',
    data: JSON.stringify(tagDTO),
    headers: {
      'Content-type': 'application/json;charset=utf-8',
    },
  })
}

export function updateTag(tagDTO) {
  return request({
    url: '/admin/updateTag',
    method: 'POST',
    data: JSON.stringify(tagDTO),
    headers: {
      'Content-type': 'application/json;charset=utf-8',
    },
  })
}

export function deleteTag(id) {
  return request({
    url: '/admin/deleteTag',
    method: 'POST',
    data: JSON.stringify(id),
    headers: {
      'Content-type': 'application/json;charset=utf-8',
    },
  })
}
